#!/user/bin/env python3
# -*- coding: utf-8 -*-
#-------------------------------------------------------------------------------
# @File : call_assert.py.py
# @Time : 2022-08-05 16:48
# @Author : mojin
# @Email : 397135766@qq.com
# @Software : PyCharm
#-------------------------------------------------------------------------------
from base.base_page import BasePage
from business.call.call_page import Call_Page
class CallAssert():
    def __init__(self,drivers_devices):

        drivers, devices, devices_info = drivers_devices
        self.d0 = BasePage(drivers[0])
        self.d1 = BasePage(drivers[1])

    def call_assert(self,expect_text):
        result=[self.d1.assert_text(*Call_Page.SearchButton,expect_text,doc='挂断后toast消息断言',assert_type="toast"),
                self.d0.assert_text(*Call_Page.SearchButton, expect_text, doc='挂断后toast消息断言', assert_type="toast"),

        ]

        return not False in result




